| API Documentation |  |

- MAIN PAGE
- NAMESPACES
- CLASSES

UserTypeFieldDescriptor.h
1 // UserTypeFieldDescriptor.h
3 //
5
6 namespace nkScripts
7 {
8 using FieldGetter = std::function<OutputValue(void*)> ;
9 using FieldSetter = std::function<void(const DataStack&)> ;
10
14 struct UserTypeFieldDescriptor
15 {
16 FieldGetter _getter ;
17 FieldSetter _setter ;
18
19 nkMemory::String _fieldName ;
20
21 // Le type de field
22 FUNCTION_PARAMETER_TYPE _fieldType = FUNCTION_PARAMETER_TYPE::INT ;
23 nkMemory::String _userTypeName ;
24 } ;
25 }
nkScripts::UserTypeFieldDescriptor::_userTypeName
nkMemory::String _userTypeName
If a user type, the type name attached.
Definition: UserTypeFieldDescriptor.h:23
nkScripts
Encompasses all API of component NilkinsScripts.
Definition: Environment.h:7
nkMemory::BufferView
A view over data.
Definition: BufferView.h:18
nkScripts::FieldSetter
std::function< void(const DataStack &)> FieldSetter
Callback function signature for a field setter.
Definition: UserTypeFieldDescriptor.h:9
nkScripts::FieldGetter
std::function< OutputValue(void *)> FieldGetter
Callback function signature for a field getter.
Definition: UserTypeFieldDescriptor.h:8
nkScripts::UserTypeFieldDescriptor::_getter
FieldGetter _getter
Callback that should be use for the getter.
Definition: UserTypeFieldDescriptor.h:16
nkScripts::UserTypeFieldDescriptor::_fieldName
nkMemory::String _fieldName
The field's name.
Definition: UserTypeFieldDescriptor.h:19
nkScripts::FUNCTION_PARAMETER_TYPE::INT
@ INT
Int variable.
nkMemory::String
Class holding information about a string, with ownership over the data.
Definition: String.h:22
nkScripts::UserTypeFieldDescriptor::_fieldType
FUNCTION_PARAMETER_TYPE _fieldType
Field's type.
Definition: UserTypeFieldDescriptor.h:22
nkScripts::OutputValue
FunctionParameter OutputValue
The ouput value for a function.
Definition: FunctionDefines.h:9
nkScripts::UserTypeFieldDescriptor::_setter
FieldSetter _setter
Callback that should be use for the setter.
Definition: UserTypeFieldDescriptor.h:17
nkScripts::FUNCTION_PARAMETER_TYPE
FUNCTION_PARAMETER_TYPE
Describes a variable type.
Definition: FunctionParameterType.h:12
nkScripts::UserTypeFieldDescriptor
Holds all the information required to define a field.
Definition: UserTypeFieldDescriptor.h:15